<div class="">
  <!--<nz-spin [nzTip]="'正在导入请等待...'" [nzSize]="'large'">-->

    <nz-collapseset>
      <nz-collapse [nzTitle]="'查询'" [nzActive]="true">
        <form nz-form [nzLayout]="'inline'">
          <div nz-row>

            <div nz-form-item nz-col [nzSpan]="6">
              <div nz-form-label nz-col [nzSm]="9" [nzXs]="6">
                <label>报表类型</label>
              </div>
              <div nz-form-control nz-col [nzSm]="12" [nzXs]="12">
                <nz-select style="width: 200px;" name="elevatorTypeId" nzAllowClear [nzPlaceHolder]="'请选择'"
                           [nzShowSearch]="true" [(ngModel)]="id">
                  <nz-option *ngFor="let data of datas" [nzLabel]="data.reportName" [nzValue]="data.id">
                  </nz-option>
                </nz-select>
              </div>
            </div>

            <!--<div nz-form-label nz-col [nzSpan]="3">
              <label>时间</label>
            </div>
            <div nz-form-control nz-col [nzSpan]="9">
              <nz-datepicker [nzSize]="'large'" [nzFormat]="'YYYY-MM-DD'" name="pStartDtShow" [nzPlaceHolder]="'开始日期'"></nz-datepicker>
              至
              <nz-datepicker [nzSize]="'large'" [nzFormat]="'YYYY-MM-DD'" name="pEndDtShow" [nzPlaceHolder]="'结束日期'"></nz-datepicker>
            </div>-->

            <button style="margin-left:40px;" nz-button [nzSize]="'middle'" [nzType]="'primary'" (click)="findReportData()" >查询</button>
            <!--<button style="margin-left:40px;" nz-button [nzSize]="'middle'" [nzType]="'primary'">导出Excel</button>-->
          </div>


        </form>
      </nz-collapse>
    </nz-collapseset>
    <ul nz-menu [nzMode]="'horizontal'">
      <li nz-menu-item (click)="add(title, content, footer)">
        <i class="anticon anticon-plus"></i>添加
      </li>
      <li nz-menu-item (click)="update(title, content, footer)" >
        <i class="anticon anticon-copy"  ></i>修改
      </li>

      <li nz-menu-item (click)="delete()">
        <i class="anticon anticon-copy" ></i>删除
      </li>
    </ul>
    <nz-table #nzTable [nzDataSource]="dataValue" nzSize="middle" [nzBordered]="true" [nzIsPagination]="false"
              (nzDataChange)="displayDataChange($event)">
      <thead nz-thead>
      <tr>
        <th nz-th [nzCheckbox]="true">
          <label nz-checkbox [(ngModel)]="allChecked" [nzIndeterminate]="indeterminate" (ngModelChange)="checkAll($event)" >
          </label>
        </th>
        <th nz-th>
          <span>报表名称</span>
        </th>
        <th nz-th [nzWidth]="'500px'">
          <span>SQL语句</span>
        </th>
        <th nz-th>
          <span>参数是否为空</span>
        </th>
        <th nz-th>
          <span>创建人</span>
        </th>
        <th nz-th>
          <span>创建时间</span>
        </th>
        <th nz-th>
          <span>修改人</span>
        </th>
        <th nz-th>
          <span>修改时间</span>
        </th>
      </tr>
      </thead>
      <tbody nz-tbody>
      <tr nz-tbody-tr *ngFor="let data of dataValue">
        <td nz-td [nzCheckbox]="true">
          <label nz-checkbox [nzDisabled]="data.disabled" [(ngModel)]="data.checked" (ngModelChange)="refreshStatus($event)">
          </label>
        </td>
        <td nz-td >{{data.reportName}}</td>
        <td nz-td>{{data.sqlSentence}}</td>
        <td nz-td>{{data.isNullParm | constantTransfer:paramePip }}</td>
        <td nz-td>{{data.createBy}}</td>
        <td nz-td>{{data.createDate | date:'yyyy-MM-dd HH:mm'}}</td>
        <td nz-td>{{data.updateBy}}</td>
        <td nz-td>{{data.updateDate | date:'yyyy-MM-dd HH:mm'}}</td>
      </tr>
      </tbody>
    </nz-table>


  <!--添加页面 -->
  <ng-template #title>
    <span>{{modelTitle}}</span>
  </ng-template>
  <ng-template #content>
    <dynamic-add *ngIf="modal==0" (outPut)="addOutPut($event)"></dynamic-add>
    <dynamic-modify *ngIf="modal==1" [inValue]="updateData" (outPut)="addOutPut($event)"></dynamic-modify>
  </ng-template>
  <ng-template #footer>
    <div>
    </div>
  </ng-template>
 <!-- </nz-spin>-->
</div>
